package reflect;

import java.lang.reflect.Field;
// 滥用
public class ReflectDemo9
{
    public static void main(String[] args) throws Exception
    {
        String s1 = "abc";
        Class aClass = Class.forName("java.lang.String");
        Field value = aClass.getDeclaredField("value");
        value.setAccessible(true);
        value.set(s1,new char[]{'G','S','D'});
        value.setAccessible(false);
        String s2 = "abc";
        String s3 = "abc";
        System.out.println("s3 = " + s3  );
        System.out.println("s2 = " + s2 );
    }
}
